package util

import (
	"gopkg.in/yaml.v3"
	"io/ioutil"
	"log"
)

func Parse_yaml(file string) map[string]interface{} {
	yfile, err := ioutil.ReadFile(file)
	if err != nil {
		log.Fatal(err)
	}
	data := make(map[string]interface{})
	err2 := yaml.Unmarshal(yfile, &data)
	if err2 != nil {
		log.Fatal(err2)
	}
	return data
}
